// 引入二次封装文件
import request from '@/utils/request';

// 去结算请求数据
export function settlement(data) {
    return request({
        url: '/api/order/settlement',
        method: 'post',
        data
    })
}

// 支付宝结算
export function alipay(data) {
    return request({
        url: '/api/pay/alipay/createOrder',
        method: 'post',
        data
    })
}

// 查询支付宝，支付宝订单状态
export function queryOrder(params) {
    return request({
        url: '/api/pay/alipay/queryOrder',
        params
    })
}


// 微信结算
export function wxpay(data) {
    return request({
        url: '/api/pay/wxpay/createOrder',
        method: 'post',
        data
    })
}

// 查询微信，微信订单状态
export function wxpayOrder(params) {
    return request({
        url: '/api/pay/wxpay/queryOrder',
        params
    })
}